Skip to content

feat: improved LaTeX check workflows #17

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 9 commits into
base: main
Choose a base branch
from

Conversation

Gavin-WangSC
Copy link
Contributor

Extended the LaTeX checks;
Moved the modificatioin process in to a while loop, to ensure the error is fixed;
Only put LaTeX errors in the prompt when requesting a rewriting (the error prompts haven't been tested yet, they are generated by llms);
Isolated LaTeX when beautifying;

Haven't test the code ever once... not sure if it works.

Copy link

netlify bot commented May 4, 2025

Deploy Preview for c13n-newsletter ready!

Name Link
🔨 Latest commit 58af49b
🔍 Latest deploy log https://app.netlify.com/sites/c13n-newsletter/deploys/68183554d912660008b8f8fa
😎 Deploy Preview https://deploy-preview-17--c13n-newsletter.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@q1zhen
Copy link
Member

q1zhen commented May 5, 2025

I think it should be included in make.py rather than the writer since we may have older files that also need fixing.

@q1zhen
Copy link
Member

q1zhen commented May 5, 2025

The code looks good for me. You could run the workflow in your forked repo to see the effects.

@RadioNoiseE
Copy link
Collaborator

Seems like the regex which matches valid TeX style math delimiters does not conform to our spec (available here).

In short, the normal dollar signs should not be escaped as in the CommonMark spec.

And I suggest using a finite state machine instead of regex to do the job. You may refer to the C implementation while implementing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants